#include<stdio.h>

int main (void)
{
	int n, i;
	double sum = 0, average, value, largest, value1  ;
	
	printf("How many values to consider: ");
	scanf("%d", &n );
	
	if(n>0){
	
	printf("Enter the value1: ");
	scanf("%lf", &value1);
	largest = value1;
	
	 
	 
	for (i=2 ; i<=n ; i++)
	{
	printf("Enter value %d: ", i);
	scanf("%lf", &value);
	if (value > largest)
		largest = value;
	sum += value;
}
	average = sum / n;
	printf("Largest value = %.2lf\n", largest);
	printf("Average = %.2lf", average);
	 

}
	 else 
	 printf("Error");


	return 0;
}


